package com.itany.cms.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.github.pagehelper.PageInfo;
import com.itany.cms.entity.CourseType;
import com.itany.cms.entity.User;
import com.itany.cms.exception.COurseTypeStatusErrorException;
import com.itany.cms.exception.CourseTypeExistException;
import com.itany.cms.exception.CourseTypeNotExistsException;
import com.itany.cms.exception.RequestParameterErrorException;

import java.util.List;

public interface CourseTypeService {
    void addFatherType(String typeName) throws RequestParameterErrorException, CourseTypeExistException;
    PageInfo<CourseType> findByParams(CourseType courseTypeParam, String pageNo, String pageSize);
    void addSonType(String parentId, String typeName) throws RequestParameterErrorException, CourseTypeExistException;
    void modifyName(String id, String typeName) throws RequestParameterErrorException, CourseTypeExistException;
    void enabledType(String id) throws RequestParameterErrorException, COurseTypeStatusErrorException;
    void disabledType(String id) throws RequestParameterErrorException;
    void modifyStatus(String id,String status) throws RequestParameterErrorException;
    List<CourseType> findEnabled() throws CourseTypeNotExistsException;
    PageInfo<CourseType> findFatherType(CourseType courseTypeParam, String pageNo, String pageSize);
    PageInfo<CourseType> findSonType(CourseType courseTypeParam, String pageNo, String pageSize);
}
